This is essentially all we can test for now, as the
methods using the Babl type are show up with 'introspectable="1"'.
CONCURRENCY_STRESS_TEST = concurrency-stress-test
endif
-TESTS = \
+C_TESTS = \
grayscale_to_rgb \
rgb_to_bgr \
rgb_to_ycbcr \
cairo-RGB24 \
$(CONCURRENCY_STRESS_TEST)
-TESTS_ENVIRONMENT = BABL_PATH=$(top_builddir)/extensions/.libs
+if HAVE_INTROSPECTION
+INTROSPECTION_TESTS = \
+ introspection.py
+endif
+
+TESTS = \
+ $(C_TESTS) \
+ $(INTROSPECTION_TESTS)
+
+TESTS_ENVIRONMENT = LD_LIBRARY_PATH=$(top_builddir)/babl:$LD_LIBRARY_PATH GI_TYPELIB_PATH=$(top_builddir)/babl BABL_PATH=$(top_builddir)/extensions/.libs
AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/babl
if OS_UNIX
EXTRA_DIST=common.inc
+noinst_SCRIPTS = \
+ introspection.py
+
noinst_PROGRAMS = \
introspect \
babl_fish_path_fitness \
babl-html-dump \
conversions \
formats \
- $(TESTS)
+ $(C_TESTS)
--- /dev/null
+#!/usr/bin/env python
+
+import unittest
+
+class TestSanity(unittest.TestCase):
+
+ def test_import(self):
+ import gi
+ from gi.repository import Babl
+
+ def test_init(self):
+ import gi
+ from gi.repository import Babl
+ Babl.init()
+ Babl.exit()
+
+if __name__ == '__main__':
+ unittest.main()